package util.AST.Expression;

import checker.SemanticException;
import checker.Visitor;
import util.AST.Terminal.Operator;


public class BinaryExpression extends Expression{

	private Expression leftExpression;
    private Operator operator;
    private Expression rightExpression;
    private String t;
    
    
    public BinaryExpression(Expression leftExpression, Operator operator, Expression rightExpression) {
            this.leftExpression = leftExpression;
            this.operator = operator;
            this.rightExpression = rightExpression;
    }
	
	public Expression getLeftExpression() {
		return leftExpression;
	}

	public Operator getOperator() {
		return operator;
	}

	public Expression getRightExpression() {
		return rightExpression;
	}

	@Override
	public String toString(int level) {
		// TODO Auto-generated method stub
		return null;
	}
	
	public BinaryExpression(String t) {
		this.t = t;
	}

	public String getT() {
		return t;
	}
	@Override
	public Object visit(Visitor v, Object o) throws SemanticException {
		// TODO Auto-generated method stub
		return v.visitBinaryExpression(this, o);
	}

	

}
